package com.example.project_speelveld;

import com.model.speelveld.GameModel;
import com.view.speelveld.GameView;
import com.view.speelveld.Statusbar;
import com.view.speelveld.Tower_Menu;

import android.os.Bundle;
import android.app.Activity;
import android.view.Menu;

public class MainActivity extends Activity {

	@Override
	protected void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.activity_main);
		
		GameModel gameModel = new GameModel();
		Statusbar statusBar = (Statusbar)findViewById(R.id.statusbar1);
		Tower_Menu towerMenu = (Tower_Menu)findViewById(R.id.towerMenu1);
		statusBar.setGameModel(gameModel);
		towerMenu.setGameModel(gameModel);
		
		GameView gameView = (GameView)findViewById(R.id.gameView1);
		gameView.setGameModel(gameModel);
	}

	@Override
	public boolean onCreateOptionsMenu(Menu menu) {
		// Inflate the menu; this adds items to the action bar if it is present.
		getMenuInflater().inflate(R.menu.activity_main, menu);
		return true;
	}

}
